1.fix over maxsize limit not delete file#139
Open
ta893115871 wants to merge 2 commits intodanikula:masterfrom
Open
1.fix over maxsize limit not delete file#139ta893115871 wants to merge 2 commits intodanikula:masterfrom
ta893115871 wants to merge 2 commits intodanikula:masterfrom
Conversation
added 2 commits
May 8, 2017 13:13
2.fetchContentInfo use http header information for faster
2.fetchContentInfo use http header information for faster
danikula
reviewed
May 8, 2017
| if (file.exists()) { | ||
| long now = System.currentTimeMillis(); | ||
| boolean modified = file.setLastModified(now); // on some devices (e.g. Nexus 5) doesn't work | ||
| boolean modified = file.setLastModified(now/1000*1000); // on some devices (e.g. Nexus 5) doesn't work |
Author
There was a problem hiding this comment.
alway throw new IOException。because in some android device file.setLastModified return false
Owner
There was a problem hiding this comment.
@ta893115871 please explain you fix. Who and when does throw IOException? Why you divide now to 1000*1000?
Author
There was a problem hiding this comment.
you can test when the cache file over maxsize limit
Owner
Owner
|
@ta893115871 some servers doesn't response to HEAD requests. What is why I removed HEAD requests |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
2.fetchContentInfo use http header information for faster